-- GENERATED SPELL FOR [Plagued Proto-Dragon] --


function spell0_23680(pUnit, Event) --@Flame Breath,n/a--
pUnit:FullCastSpellOnTarget(9573,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23680', 2000, 1)
end

function spell1_23680(pUnit, Event) --@Thrash,Self--
pUnit:FullCastSpellOnTarget(3391,pUnit)
pUnit:RegisterEvent('Sorts_23680', 539, 1)
end

function Sorts_23680(pUnit, Event)
local choix_sorts_23680 = math.random(0, 1)
if choix_sorts_23680 == 0 then
pUnit:RegisterEvent('spell0_23680', 1, 1)
end
if choix_sorts_23680 == 1 then
pUnit:RegisterEvent('spell1_23680', 1, 1)
end
end

function mob23680_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_23680', math.random(1500, 3000), 1)
end

function mob23680_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23680_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23680_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(23680, 1, 'mob23680_Action')
RegisterUnitEvent(23680, 2, 'mob23680_Leave')
RegisterUnitEvent(23680, 3, 'mob23680_Kill')
RegisterUnitEvent(23680, 4, 'mob23680_Die')
